/** 首页相关 */
import request from '@/utils/request'

// 订单列表
export function list(params) {
	return request({
		url: '/technicianapp/Order/orderList',
		method: 'get',
		params
	})
}

// 订单详情
export function detail(params) {
	return request({
		url: '/technicianapp/Order/orderDetails',
		method: 'get',
		params
	})
}

// 订单激活步骤
export function orderSteps(params) {
	return request({
		url: '/technicianapp/Order/getOrderStatusRecord',
		method: 'get',
		params
	})
}

// 接单
export function takeOrder(params) {
	return request({
		url: '/technicianapp/Order/orderReceiving',
		method: 'get',
		params
	})
}

// 出发
export function setOut(data) {
	return request({
		url: '/technicianapp/Order/setOut',
		method: 'post',
		data
	})
}

// 到达（开始服务）
export function startService(params) {
	return request({
		url: '/technicianapp/Order/orderService',
		method: 'get',
		params
	})
}

// 结束（完成服务）
export function endService(data) {
	return request({
		url: '/technicianapp/Order/completeOrder',
		method: 'post',
		data
	})
}

// 报备可选列表
export function reportList(data) {
	return request({
		url: '/technicianapp/Order/reportTypes',
		method: 'post',
		data
	})
}

// 提交报备
export function reportSubmit(data) {
	return request({
		url: '/technicianapp/Order/report',
		method: 'post',
		data
	})
}

// 报备详情
export function reportDetail(params) {
	return request({
		url: '/technicianapp/Order/getOrderRecordList',
		method: 'get',
		params
	})
}

// 评价可选列表
export function commentList(data) {
	return request({
		url: '/technicianapp/Order/commentTypes',
		method: 'post',
		data
	})
}

// 提交报备
export function commentSubmit(data) {
	return request({
		url: '/technicianapp/Order/comment',
		method: 'post',
		data
	})
}

// 紧急救助
export function callPolice(data) {
	return request({
		url: '/technicianapp/Index/callPolice',
		method: 'post',
		data
	})
}